package org.zlpt.entity.co;

import lombok.Data;
import org.hyperledger.fabric.contract.annotation.DataType;
import org.hyperledger.fabric.contract.annotation.Property;

import java.util.Date;

@Data
@DataType
public final class SupplementaryArgeementCO {
    //补充协议

    public static final String keyPrefiex = "bms_supplementary_argeement:";

    //协议id
    @Property()
    private Integer suppAgrId;
    //出租方id
    @Property
    private Long lessorId;
    //承租方id
    @Property
    private Long lesseeId;
    //时间
    @Property
    private Date suppAgrTime;
    //协议内容
    @Property
    private String suppAgrContent;
    //出租方签字
    @Property
    private String lessorSign;
    //补充协议状态
    @Property
    private Integer suppAgrStatus;
    //承租方签字
    @Property
    private String lesseeSign;


    public String formKey() {
        return keyPrefiex + suppAgrId;
    }
    public static String formKey(Long userId) {
        return keyPrefiex + userId;
    }
}
